package com.life.wd.service;

import com.life.wd.dto.ProductAddRequest;
import com.life.wd.dto.ProductQueryRequest;
import com.life.wd.dto.ProductUpdateRequest;
import com.life.wd.result.PageResult;
import com.life.wd.vo.ProductVO;

import java.io.IOException;

public interface ProductService {
    /**
     * 添加产品
     * @param request 产品添加请求
     * @return 产品ID
     */
    Long addProduct(ProductAddRequest request) throws IOException;

    PageResult listProducts(ProductQueryRequest queryRequest);

    ProductVO getProductById(Long id);

    boolean updateProduct(ProductUpdateRequest request) throws IOException;

    boolean deleteProduct(Long id);
}
